import type { Category } from '../types';
export const nodeCategories: Category[] = [
  {
    id: 'control',
    title: '流程控制',
    name: 'control',
    label: '流程控制',
    nodes: [
      {
		id:"",
        type: 'condition',
        label: '条件',
        icon: 'Switch',
		width:500,
		color:"#1a3d1a",
		data:{
		  outs: [
		    {
		      id: 'outcondition',
			  type:'exec',//exec|value
		      field: {
		        id: 'field1',
		        name: '',
		        code: 'url',
		        type: 'exec',
				exec:true,
		        value: ''
		      }
		    },
			{
			  id: 'outcondition2',
			  type:'value',//exec|value
			  field: {
			    id: 'field1',
			    name: '宽宽宽宽宽',
			    code: 'url',
			    type: 'string',
				exec:true,
			    value: ''
			  }
			},
		  ]
		}
      }
    ]
  },
  {
    id: 'action',
    title: '动作',
    name: 'action',
    label: '动作',
    nodes: [
      {
		id:"http_id",
        type: 'http',
        label: 'HTTP请求1',
        icon: 'Link',
		width:250,
		color:"#1a3d1a",
		data:{
          inputs: [
            {
              id: 'input1',
			  type:'exec',//exec|value
              field: {
                id: 'field1',
                name: '',
                code: 'url',
                type: 'exec',
				exec:true,
                value: ''
              }
            },
            {
              id: 'input2',
              type:'value',//exec|value
              field: {
                id: 'field2',
                name: '宽度宽宽宽宽宽宽宽宽宽宽',
                code: 'method',
                type: 'string',//boolean |string | float |int | objct
                value: 'POST'
              },
            }
          ],
          outs: [
            {
              id: 'out1',
			  type:'exec',//exec|value
              field: {
                id: 'field1',
                name: '',
                code: 'url',
                type: 'string',
				exec:true,
                value: ''
              }
            },
          ]
        }
      },
      {
		id:"",
        type: 'mqtt',
        label: 'MQTT消息',
        icon: 'Message',
		width:500,
		color:"#1a3d1a",
      }
    ]
  }
]; 